{% extends "wltheme/accounts/account_form.html" %}
{% load i18n future %}

{% block main %}

    {% if request.user.is_authenticated %}
        <p>{% trans "You're already logged in. If you'd like to log in as a different user, you'll need to log out first." %}</p>
    {% else %}
        <div class="am-g">
            <form method="post" class=" am-form am-form-horizontal  am-u-sm-centered">
                {% csrf_token %}
                <div class="am-form-group">
                    <label for="{{ form.username.id_for_label }}" class="am-u-sm-3 am-form-label">用户名:</label>

                    <div class="am-u-sm-4">
                        {{ form.username }}
                    </div>
                    <div>
                        {{ form.non_field_errors }}
                    </div>
                </div>
                <!-- end username -->
                <div class="am-form-group">
                    <label for="{{ form.password1.id_for_label }}" class="am-u-sm-3 am-form-label">密码:</label>

                    <div class="am-u-sm-4 am-u-end">
                        {{ form.password }}
                    </div>
                </div>
                <!-- end password1 -->
                <div class="form-actions">
                    <input class="am-btn  am-btn-primary am-u-sm-7" type="submit" value="{{ title }}">
                </div>

            </form>
        </div>
        {% url "signup" as signup_url %}
        <p>{% blocktrans with request.GET.next as next %}If you don't have an account you can
            <a href="{{ signup_url }}?next={{ next }}">sign up</a> for one now.{% endblocktrans %}</p>
        {% url "wenlincms_password_reset" as password_reset_url %}
        {% url "profile_update" as profile_update_url %}
        {% blocktrans %}
            <p>You can also <a href="{{ password_reset_url }}?next={{ profile_update_url }}">reset your password</a> if
                you've forgotten it.
            </p>{% endblocktrans %}
    {% endif %}

{% endblock %}
